package net.ossrs.yasea;


public class YaseaEncoder {

  public native void setEncoderResolution(int outWidth, int outHeight);

  public native void setEncoderFps(int fps);

  public native void setEncoderGop(int gop);

  public native void setEncoderBitrate(int bitrate);

  public native void setEncoderPreset(String preset);

  public native byte[] NV21ToI420(byte[] yuvFrame, int width, int height, boolean flip, int rotate);

  public native byte[] NV21ToNV12(byte[] yuvFrame, int width, int height, boolean flip, int rotate);

  public native int NV21SoftEncode(byte[] yuvFrame, int width, int height, boolean flip, int rotate, long pts);

  public native boolean openSoftEncoder();

  public native void closeSoftEncoder();
}
